package pers.zc.activiti.shejimoshi.zhuangtai.type;

import pers.zc.activiti.shejimoshi.zhuangtai.node.Node;

/**
 * @Annotion: 启动
 * @ClassName: TypeB
 * @Author: Lin Fuyuan
 * @Date: 2019/11/16  19:27
 * @Version: 1.0
 */
public class TypeRunning extends Type {
    private String status = null;
    private String date = null;

    public String getStatus() {
        return status;
    }
    public String getDate() {
        return date;
    }

    @Override
    public void run(Node node) {
        System.out.println("running");
        if(node.getStatus().equals("异常")){
            node.setType(new TypeFiled());
        }else{
            node.setType(new TypeDone());
        }

    }

    public static String result(){
        return "运行中";
    }
}
